﻿@model SoftHotel.Models.Horario

@{
    ViewBag.Title = "Trabajadores: Agregar horario";
}

<h2>Agregar horario</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Horario</legend>

        <div class="editor-label">
            @Html.LabelFor(model => model.trabajador)
        </div>
        <div class="editor-field">
            @Html.DropDownList("idTrabajador")
            @Html.ValidationMessageFor(model => model.idTrabajador)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.sede)
        </div>
        <div class="editor-field">
            @Html.DropDownList("idSede")
            @Html.ValidationMessageFor(model => model.idSede)
        </div>
          <div class="editor-label">
            @Html.LabelFor(model => model.pTurno)
        </div>
        <div class="editor-field">
            @Html.DropDownList("turno", String.Empty)
            @Html.ValidationMessageFor(model => model.turno)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.pEstado)
        </div>
        <div class="editor-field">
            @Html.DropDownList("estado")
            @Html.ValidationMessageFor(model => model.estado)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.fechaInicio)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.fechaInicio)
            @Html.ValidationMessageFor(model => model.fechaInicio)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.fechaFin)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.fechaFin)
            @Html.ValidationMessageFor(model => model.fechaFin)
        </div>

        <p>
            <input type="submit" value="Guardar" />
        </p>
    </fieldset>
}

<div>
    @Html.ActionLink("Regresar", "Details", new { id = ViewBag.idT })
</div>
